package edu.spec.lyq.week09.class2.home.work1;

/**
 * \* User: 11028
 * \* Date: 2018/10/27
 * \* Time: 14:50
 * \* Description:0、设计食物类Food
 * 成员属性1，姓名，name，String类型，访问类型为private
 * 成员属性2，价格，price，int类型,访问类型为private
 * 构造方法：自行设计
 * 成员方法：成员属性对应的setter和getter
 */
public class Food {
    private String name;
    private int price;

    public Food() {
    }
    public Food(String name, int price) {
        this.name = name;
        this.price = price;
    }

    public String getName() {
        return name;
    }

    public int getPrice() {
        return price;
    }

    public void setName(String name) {
        this.name = name;
    }

    public void setPrice(int price) {
        this.price = price;
    }
}
